<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>考研英语和数学面试题</title>
    <style>
        body {
            font-family: Arial, sans-serif;
            margin: 0;
            padding: 0;
            background-color: #f4f4f4;
        }

        .container {
            display: flex;
            flex-direction: column;
            justify-content: center;
            align-items: center;
            align-content:center;
            height: 100vh;
            width:100vw;
        }
        .speed-container {
            display: flex;
            flex-direction: row;
            justify-content:space-between;
        }
        .hidden {
            display: none;
        }

        .home-container {
            display: flex;
            flex-direction: column;
            margin-bottom: 20px;
        }

        .question-container {
            background-color: #fff;
            border: 1px solid #ddd;
            padding: 15px;
            margin: 0;
            margin-bottom: 10px;
            border-radius: 5px;
            box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
            display: flex;
            flex-direction: column;
            align-items: center;
            transition: opacity 0.3s ease;
        }

        .question {
            margin-bottom: 10px;
            font-size: 1.2rem;
            padding: 10px;
            font-weight:bold;
        }

        .answer {
            color: rgb(62, 41, 41);
            display: none;
            margin-bottom: 10px;
            font-size: 1rem;
            line-height: 1.6;
            width: 80vw;
        }

        .button-container1,.button-container2 {
            display: flex;
            flex-direction: row;
            justify-content: center;
            /* justify-content: space-between; */
            margin-top: 10px;
        }

        .button {
            padding: 5px 10px;
            border: none;
            border-radius: 2px;
            cursor: pointer;
            font-size: 0.7rem;
        }

        #showQuestion {
            padding: 10px 15px;
            border-radius: 5px;
            font-size: 1.2rem;
            margin:5px auto;
            width:20vw;
            background-color: #79b0e0;
            color: white;
        }

        #show-hide-answer,
        .fanyi,
        .return-home,
        .prev-question,
        .next-question,
        .random-question,
        .hide-answer {
            width:5rem;
            background-color: #5cb85c;
            color: white;
            margin:1px 5px;
        }
        /* 播放速度菜单样式*/
        #speed-describtion {
            font-size: 1rem;
        }
        .play-question ,
        .play-answer {
            background-color: #6ebadd;
            color: white;
        }
        /* 标签样式 */
        /* label {
            display: block;
            margin-bottom: 5px;
            font-weight: bold;
        } */
        /* 输入框样式 */
        input[type="range"] {
            width: 20%;
        }
        
    </style>
</head>

<body>
    <div class="container">
        <div class="home-container">
            <div><h2>请选择科目：</h2></div>
            <button class="button" id="showQuestion" onclick="showQuestions('english')">考研英语面试题</button>
            <button class="button" id="showQuestion" onclick="showQuestions('math')">首经贸应统题</button>
        </div>
        <div id="questionContainer" class="hidden">
        </div>

     </div>

    <script>
        const synth = window.speechSynthesis;  
        let isPlaying1 = false; // 用于跟踪问题播放的状态  
        let isPlaying = false;  // 用于跟踪答案播放的状态  
        let utterance;         // 用于存储当前的 SpeechSynthesisUtterance 实例  
        synth.rate = 1;
        const homeContainer = document.querySelector('.home-container');
        const questionContainer = document.getElementById('questionContainer');
        let currentQuestionIndex = 0;

        const questionsAndAnswers = [{
                english: [// 问题00
            {
                question: "自我介绍0:(self-introduction) <br> Please introduce yourself.",
                answers: ["Good morning/aftermoon,dear professors.My name is Zhang Yongjian. I graduated from Hebei Normal University of Science & Technology with a major in Applied Statistics in 2023. During my undergraduate studies, I worked diligently and achieved an average GPA of 3.52 out of 4, earning scholarships for three consecutive years. I was also actively involved in various academic competitions, leading my team to win the third prize in the Asia-Pacific Cup and the Teddy Cup National Data Mining Competition. Additionally, I participated in a research project on 'The Study of Electric Vehicle Charging Station Resource Allocation and Optimal Pricing Mechanisms' under the guidance of my teacher, and successfully obtained funding for a youth fund project from the Education Department for Humanities and Social Science Research in Colleges and Universities. My undergraduate graduation paper, 'Diagnosis of Alzheimer's Disease Based on Machine Learning' was also awarded the title of Excellent Graduation Paper."],
                id: "question00"
            },
            // 问题01
            {
                question: "自我介绍1： ",
                answers: ["Good morning/aftermoon,dear professors.I am very glad to be here for your interview.Mynameis(姓名)am(年龄)years old.l come from (家乡),My undergraduate period will be finished in (本科学校的名称)in (毕业时间).<br>I am a very hard-working person with great perseverance.(可替换为其他品质) In order to get a satisfactory result in thepreliminary test,l began to prepare for the postgraduate examination since I was a sophomore.And from then on, keptrunning everyday no matter what the weather was,so my physical fitness as well grades both improved.in my spare time,!also did some part-time jobs.such as a family tutor.(可替换为其他兼职活动)With joint efforts,one of my students hasranked the fifth in his class.In the process,I also gained knowledge.In daily life,I am a warm-hearted person.( 可替换为其他性格特质)Owing to my kindness,I made a lot of firiends in the university.<br>This is all for my self-introduction.f 1 am lucky enough to pass second-round examination,I will devote all myself to thefuture researching.Thanks for your attention.",
                ""],                
                id: "question01"
            },
            // 问题02
            {
                question: "自我介绍2： ",
                answers: ["Good morning/aftemoon,dear teachers.l am very glad to be here for your interview.My name is(姓名), am(年龄)years old.I come fiom(家乡)a very beautiful ancient city.My undergraduate period will be finished in (本科学校的名称) in (毕业时间).<br>I don't aim for success,but just do what I love and I believe that success will come naturally.(可换为其他的观点.信仰、座右铭) I have a keen interest in web design.in high school,I tried to design a homepage by myself.Although it tookme half a month.l succeeded.That made me firmly determine to study Computer Science in the university and continue todo what I love.ln addition, in order to improve my competitiveness.l have taught myself a lot of knowledge and methodsabout art and design in the university,which will be of great help to my future graduate study or job search.(可换为其他技能)Besides computer,I also like leamning English.(可替换为其他兴趣爱好)Not only did I pass CET-6 with highmarks ,but also my listening comprehension and oral ablility are very good.Because l listen to Fox News every day,at thesame time,I find partners through foreign social software to practice my oral English.OK,that is all.Thanks for you attention.",
                ""],                
                id: "question02"
            },
            // 问题02
            {
                question: "自我介绍3： ",
                answers: ["Good morning/afternoon, dear professors. I am very glad to be here for this interview, Myname is(始名), I'vefinished my undergraduate educationin (本科学校的名称),majoringin(本科专业).<br>I like my major, Mass Communication, very much.(可替换为其他专业) In the past three and a half years, I have notonly worked hard to lear professional knowledge, but also participated in a number of practical activities, such as being animntern in the news channel of provincial TV station.(可换为其他实习经历业)Although I grasp the essential knowledgeof the major, I think at present, owing to insuficient knowledge and inadequate ability, I'm not very competent to deal withsome professional things beyond (out of) my grasp. So fiurther study is urgent for me to realize my self- value. The major thatI hope to pursue for my further education is Journalism and Communication.(可换为其他专业)Information is playingan inereasingly important role in our modern society. And nowadays in China, with the recognition of the goverment, ourdomestic news and information industry is growing rapidly and this may provide us with a lot of chances.<br>OK, that's all. Thank you very much.",
                ""],                
                id: "question02"
            },
            // 问题1
            {
                question: "情景问题1:未听清或未听懂问题时",
                answers: ["1. Sorry,I did not understand the question,could you repeat it in another way?", 
                        " 2. Sorry,did not really understand what you mean,could you explain the queston,please?", 
                        " 3. I am sorry.I did not quite understand that,could you repeat it for me,please?",
                        " 4. Sorry,did not understand the word + 某单词,could you explain it,please?"],
                id: "question1"
            },
            // 问题2
            {
                question: "情景问题2:老师多次重复问题后，还不理解或不会时",
                answers: [" 1. Sorry,I am sure about how to answer it,but I guess ...", 
                " 2. Sorry,I can not give you an excellent answer,but I guess ...", 
                " 3. I am sorry,but I do not konw much about ..."],
                id: "question2"
            },
            // 问题3
            {
                question: "情景问题3:老师误解或没理解你的回答时",
                answers: ["1. (误解时)Sorry,maybe you mistaken I,can you give me a chance to explain?", 
                "2. (误解时)Sorry,I guess you did not understand it,can you give me a chance to explain?", 
                "3. (未理解时)Sorry,I will (try to) explain it in a more reasonable way.",
                "4. (未理解时)Sorry,I will make a more rational explanation for you.",
                "5. (通用)Excuse me,I guess I did not make myself clear.May I explain furter?",
                "6. (通用)May I try to explain myself in anoter way?"],
                id: "question3"
            },
            // 问题4
            {
                question: "情景问题4:回答得到老师肯定，如何表示感谢和态度",
                answers: ["1. Thank you for your encouragement, I will go further to enrich my knowledge.", 
                "2. Your appreciation really inspirs me,I will make more efforts to improve myself.", 
                "3. Thanks for your compliment.I am far from perfect.I will continue to work hard in the furture."],
                id: "question4"
            },
            // 问题5
            {
                question: "情景问题5:复试时紧张，如何拖延思考时间？",
                answers: ["1. In regard to ... actually,I ever thought about it...", 
                "2. It is something like ...", 
                "3. As you know,...",
                "4. It goes without saything ... ",
                "5. You konw ..."],
                id: "question5"
            },
            // 问题6
            {
                question: "自我认知问题1:hobby<br>What is your favorite hobby(interest)?<br>Describe one of your hobbies.",
                answers: ["1. I enjoy reading biographies, especially those of well-known statesmen, militarists, scientists and artists. I can learn a lotfrom their life histories. Reading is not like watching Tv, Watching TV does not require a process of thinking activities.Reading is a proactive learning process that will make our thinking agile, so I will keep reading.",
                "2. I deeply love programming. It's like a child that I nurture with my own hands, growing stronger and stronger. I pour my heart and soul into perfecting it, just like carefully nurturing a child. Whenever I complete a program, I feel a sense of pride and accomplishment. And when it's used by others, I feel even more proud and joyful."],
                id: "question6"
            },
            // 问题7
            {
                question: "自我认知问题2: personal or strengths <br> What are your personal strengths?",
                answers: ["1. I like video editing. Before, my parents wanted me to make a complete video of family trips, so i learned to use professionalediting software by myself. Through studying, I can skillfully use Premiere. Later, with the improvement of my ability, leven found a part-time job and got paid for my efforts. 'Thanks to my specialty, not only does it help me master one moretechnique, but also enriches the contents of my life.", 
                "2. I am passionate about programming and have learned various programming languages, including Python, MATLAB, R, Java, C, and HTML. However, I am aware that there is still room for improvement, and I continue to strive for excellence. Through learning these languages, I have gained a lot and realized the beauty of combining mathematics with computers. Additionally, I have utilized my knowledge to take on part-time online jobs to supplement my income."],
                id: "question7"
            },
            // 问题8
            {
                question: "自我认知问题3: strengths or merits <br> What do you think your strengths? <br> What is your greaters strength? <br> Do you have any particularmerits?",
                answers: ["1. As for my strongest strengths, I think they are my carefulness and responsibility in work and study. In the second semesterof my third year, my teacher asked us to shoot a short film in groups. Although we have written the script, we inadvertentlymissed a shot in the actual operation, in order to have a better effect, I persuaded the actors to go to the location we hadchosen before to complete the re-shooting. When we saw the complete video, everyone thanked me very much. Throughthis matter, I find that carefulness and responsibility are very important. And i will stick to them in the following work.", 
                "2. I think my strengths now are perseverance and emotional stability. When I encounter problems, I will first calm down and make a plan before taking action, instead of acting impulsively as before. I used to be easily anxious, but now I have learned to think before acting. This change has made me more mature and steady when dealing with issues."],
                id: "question8"
            },
            // 问题9
            {
                question: "自我认知问题4: weakness or shortcoming <br> What do you think about your weakness? <br> What is your greatest strength shortcoming?",
                answers: ["1. Sometimes, I can be too straightforward when I'm pursuing things, so l am not very sensitive to other people's feelings occasionally. My straightforwardness does have a positive impact on my work and study, but I should also consider thefeelings of my friends around me, so as to prevent myself from blurting out some unintentional words that hurt them.", 
                "2. I think I have some shortcomings. Firstly, I'm not good at refusing others' requests. As long as I can do it, I will always try my best to help. Secondly, my self-control needs to be improved. Sometimes, I need others' reminders and supervision to complete tasks.To improve these weaknesses, I will strive to learn to refuse appropriately and enhance my self-control so that I can better manage my time and tasks."],
                id: "question9"
            },
            // 问题10
            {
                question: "自我认知问题5: where are you from or hometown <br> Where are you from? <br> Tell something about your hometown. <br> Would you like to tell some stories about your hometown?",
                answers: ["1. I am from Xi'an, the capital city of Shaanxi province, which is considered as one of the cradles of Chinese civilization.Qingiang opera is quite popular in this area characterized by its straightforwardness and enthusiasm, so people here arestraightforward and full of passion as well, and I'm no exception, Because of my good character, l made many like-minded fiends in university.", 
                "2. I come from Langfang City, Hebei Province. Located between Tianjin and Beijing, Langfang is known as the 'Pearl on the Beijing-Tianjin Corridor'. It boasts rich historical heritage and cultural traditions, and has been called the 'Emperor's Crossing' since ancient times. For me personally, Langfang is not only the place where I grew up, but also a home filled with countless wonderful memories."],
                id: "question10"
            },
            // 问题11
            {
                question: "自我认知问题6: family <br> Could you tell me something about your family?",
                answers: ["1. My family is not big but very warm and harmonious. There are three people in my family:father, mother and L. My dadprobably influenced me the most. He works in a private high school as a vice-headmaster. Whenever l encounter difficultieshe can guide me to look at problems from a positive perspective, which makes me develop an optimistic atitude towards lifeI would also like to thank my mom, she is the glue to keep our family together and harmonious. I will try my best to live upto their expectations and show much gratitude to them.", 
                "2. My family consists of four members: my dad, mom, younger sister, and me. My parents are diligent farmers. Dad often goes out to work, while mom stays at home to take care of us. My sister is now a university student who studies hard and makes us all proud. Although my parents work hard to support our family, we live in harmony and love. I will strive to fulfill our family's expectations and create a better future together."],
                id: "question11"
            },
            // 问题12
            {
                question: "社会实践问题1:  internship  <br> Please introduce your internship briefly. <br> What have you learned from your internship experience?",
                answers: ["1. I was a lab assistant before at the beginning i didn't adapt to the closed environment and regulated operation of thelaboratory. I thought it was boring. But as I did more experiments, i gradually adapted to that environment. When workingin the laboratory, if I had any questions, I can consult teacher in time. As a person who has had the experience, the teachertaught me something new, In the process of intership I was more interested in Chemistry, so I should continue to study inorder to improve my education and be able to enter the research institute which i dream of after graduation.", 
                "2. I was an intern data analyst, feeling confident at first, but I faced challenges when actually working. As the workload increased, I gradually got the hang of it. Whenever I encountered problems, I actively sought advice from my seniors and looked up information to solve them. I also realized my knowledge was limited, so I’ve decided to further my studies to improve myself."],
                id: "question12"
            },
            // 问题13
            {
                question: "社会实践问题2:  scientific research <br> Could you say something about your experice of scientific research?",
                answers: ["1. Under the guidance of my teachers, I did research on (研究课题) with my classmates when I was a sophomore. In theprocess of researching, everyone spared no efforts to complete the task, and my responsibility was to (自己负责的内容). Inorder to finish the research, we read and checked many books and articles, such as( 查阅的文). We also applied diemethod of (具体的方法) to solve the problems we encountered. Through this research, we have solved some problems, butalso found some problems. I find that knowledge is limitless, which firms my determination to further my study.", 
                "2. During my time at school, I had the privilege to join a teacher’s research group focusing on parking issues. I was mainly responsible for theoretical validation and coding. Throughout this experience, I learned a lot from the teachers. In the end, our project was successfully funded by a youth research grant."],
                id: "question13"
            },
            // 问题14
            {
                question: "社会实践问题3: (往届生)experience of your job or work experience <br> Could you say something about your experience of your job?",
                answers: ["1. I worked as a personnel manager in a state-owned company, and then I transferred to a joint venture as a sales manager, Oneof the most important things I have leared is that how to deal with clients. Although I am familiar with the market, I alwaysthink practice requires theoretical guidance and advanced theory instruction often can indicate the direction for the practiceSo I hope to continue to study in university.", 
                "2.  I used to be a high school math teacher. During that time, I learned how to interact with students, maintain emotional stability, and master proper teaching methods. I also realized the importance of theory in guiding practice, so I hope to continue learning for more advanced theoretical knowledge.", 
                ""],
                id: "question14"
            },
            // 问题15
            {
                question: "本科学习问题1: professional books or main idea  <br> What professional books have you read before? <br> What's the main idea of this text?",
                answers: ["1. Journalism shares varlous similarities with culture, cross-culture is also an important branch of interational communication.When I was a sophomore, I had read a book named The Chrysanthemum and the Sword, written by Ruth Benedict. Thebook depicts the rooted characteristics of Japanese through thorough investigations, interviews and participation. From her book, I have gained a closer eye on Japanese and Japanese culture, which is good for me to learn Cross-CulturalCommunication.", 
                "2. During my time at school, studying “Multivariate Statistical Analysis” was a turning point for me. It opened up a new world of data analysis and inspired my first blog post. The book deepened my understanding of data processing and analysis, and I gained a lot from it."],
                id: "question15"
            },
            // 问题16
            {
                question: "本科学习问题2: university  <br>  Could you tell us something about your university?",
                answers: ["1. I had studied in Xi'an University of Technology since 2017. Although it is not well-known, I still appreciate it because itoffers me a chance to develop my abilities. During my college years, I have made a rapid and great progress in many areasAs a student, I studied very hard, obtained scholarship many times, and also gained good comments from teachers andclassmates. Four years’ study had made me an independent, optimistic and strict boy. I really appreciated the education my university gave me.",  
                "2. I graduated from Hebei Normal University of Science and Technology. It’s not a famous school and my college years were during the pandemic, but I’m grateful because it gave me the chance to improve myself. During my time there, I won several scholarships and was recognized by my classmates and teachers, which also made me more independent and optimistic. "],
                id: "question16"
            },
            // 问题17
            {
                question: "本科学习问题3： favorite subject  <br>  What is your favorite subject and why?",
                answers: ["1. My favorite course is lnsurance Law, Because the teacher of this course has a strong personal style and academc contidenceHe sometimes spoke English and Japanese, introduced different regulations on the same issue of Insurance Law in theUnited States and Japan, and traced the origin of such diferences. This course broadened my vision and inspired my interestin learning.",
                "2. During my time at school, studying “Multivariate Statistical Analysis” was a turning point for me. It opened up a new world of data analysis and inspired my first blog post. The book deepened my understanding of data processing and analysis, and I gained a lot from it."],
                
                id: "question17"
            },
            // 问题18
            {
                question: "本科学习问题4： prizes  or  honors and awards  <br>  Have you ever won any prizes in university? <br> Did you get any honors and awards at colledge?",
                answers: ["1. I have won the University Scholarship for three years in succession. I have made a lot of efforts for this. Before otherstudents got up, I began to recite the texts on the rooftop. In the evening, I won't leave unless the library is closed. Althoughthe process is hard, I did gain knowledge, skills, honor and experience that other students do not have. That hard work isnothing compared to these gains. I will continue to work hard to achieve better results.",
                "2. During my time at school, I won scholarships for three years straight, earning multiple school-level and national awards. Even though it was tough, I gained valuable experience and skills, and earned honors. I know I still have room to improve, so I’ll keep studying hard to achieve even better results."],                
                id: "question18"
            },
            // 问题19
            {
                question: "本科学习问题5： graduation thesis  or  design process <br> Please talk about the design process of your graduation thesis. <br> Please introduce your graduation thesis.",
                answers: ["1. My undergraduate thesis is (论文名) . It is mainly about(主要内容) . During preparation for this thesis, under the guidanceofmy supervisor(导师姓名)_,I read many relevant articlessuchas(参考论文1)_and(参考论文2),and referred to someliterature especially the book(参考书目)_, which gave me lots of enlightenment. At last, this paper was published on (i论文发表所在地),and luckily gained the honor of“(荣誉称号).” Through this thesis, I leamed a lot not only in professionalaspects, but in the way of dealing with all kinds of issues, which have laid a solid foundation for my fiture graduate study.",
                "2. My undergraduate thesis, “Diagnosis of Alzheimer’s Disease Based on Machine Learning,” focused on training models to analyze key medical data and identify the main features leading to the disease. I referenced papers like “Data Preprocessing and Auxiliary Diagnostic Models for Alzheimer’s Disease,” which provided me with many insights. Under the guidance of Professor Zhang, my thesis was selected as an outstanding graduation thesis."],                
                id: "question19"
            },
            // 问题20
            {
                question: "报考动机问题1： graduate scool  or  postgraduate entrance examination <br> Why do you want to go to graduate school? <br> Why did you prepare for the graduate school entrance exam(this year's postgraduate entrance examination)?",
                answers: ["1. Firstly, when I was a junior, I asked my teacher about(对与自己专业有惑的点) , heshe gave me a brief explanation andtold me that if I wanted to get real advancement in my major, further education would be a best choice. Secondly, I am not aperson who is easily satisfied with the present accomplishment and it is still urgent for me to pursue further study just out ofmy inner obsession with the major. To sum up, I am determined to take the postgraduate entrance examination.",
                "2. Firstly, I feel that my undergraduate studies had a limited platform and insufficient knowledge, so I hope to continue learning to gain more knowledge and meet more outstanding people. Secondly, I have a strong interest in data analysis. Lastly, I expect to transform myself through postgraduate studies, becoming more excellent and confident."],                
                id: "question20"
            },
            // 问题21
            {
                question: "报考动机问题2： choose this major <br> Why do you choose this major?",
                answers: ["1. Firstly, I have always been interested in this major, and that is what my undergraduate major is. English is a universallanguage and it is a carrier of culture, through which we can know the local customs of various countries. Secondly, I havelearmed a lot of professional knowledge and skills of the major at school, but during my internship period, I have foundthere is still much to study, so it is very necessary and urgent for me to further develop in this major. In conclusion, The basis of my decision on further study is to choose the major which I am familiar with and deeply in love with.",
                "2. Firstly, I’m passionate about my undergraduate major, which is statistics. Statistics plays a crucial role in various fields, from businesses to national governance. Secondly, the knowledge I gained at school often feels inadequate when put into practice, making further study very necessary."],                
                id: "question21"
            },
            // 问题22
            {
                question: "报考动机问题3： change your major <br> Why do you change your major?",
                answers: ["1. I show keen interest in the Journalism&Communication, even though my major is Mass Communication. MassCommunication is too abstract, far away from the real world. I don't mean that Mass Communication is useless, but it is notattractive enough for me. Journalism&Communication is just the opposite, it seems more challenging, and promising for myfuture carer. That's why I made up my mind to change my major.",
                ""],                
                id: "question22"
            },
            // 问题23
            {
                question: "报考动机问题4： choose to study at our school <br> Why do you choose to study at our school",
                answers: ["1. Firstly, Peking University has been my dream school. During the College Entrance Examination, I failed to be enrolled inthis university and now I want to fulfill my dream. Secondly, I'm deeply attracted by the academic atmosphere, as well asthe youthful spirit of students in this university. More importantly, Peking university has a good reputation in the field wheremy research interest lies and so many excellent teachers who have strong research abilities. Those are the reasons why ichoose to further my study here.",
                "2. Firstly, Capital University of Economics and Business treats students from non-elite schools fairly. Secondly, although it’s not a 985 institution, its location in Beijing offers superior resources. Furthermore, the university’s Applied Statistics program is well-known."],                
                id: "question23"
            },
            // 问题24
            {
                question: "报考动机问题5： go back to study instead of going on with your work <br> Why do you want to go back to study instead of going on with your work?",
                answers: ["1. The more l experienced, the clearer I realized that I'm really interested in Business Administration. At work, I found a lot ofproblems, for instance, the management of many companies can not keep up with their development speed. And solvingsuch problems requires a lot of expertise. So I hope to continue further study in this university. That's why I resigned andstarted the way to pursue my studies.",
                "2. The more experiences I have, the more I realize the limitations of my previous knowledge. Many issues require more specialized knowledge to address. This is why I want to continue learning."],                
                id: "question24"
            },
            // 问题25
            {
                question: "未来规划问题1： What will you do after graduation?",
                answers: ["1. I would like to divide my future plans into following two parts. If l can be given a chance for further education, I will make good use of the two/three years in this university. If possible, I will purse the doctorate in this field. IfI am not admitted, l will find a job to accumulate practical experience. Besides, I will keep improving myself and make good use of spare time to prepare for the next postgraduate entrance examination, because I'm the kind of person who seldom gives up.",
                "2. My plan for the future has two parts: if I can continue studying, I will make the most of my time to deepen my professional knowledge and aim for a doctoral degree. If not, I will start working, gain experience, and continue studying for the next exam."],                
                id: "question25"
            },
            // 问题26
            {
                question: "未来规划问题2： research direction <br> Which research direction do you like and why?",
                answers: ["1. I opt for the cell biology as the direction of my research. Firstly, the research is very attractive to me. Cells are the basicunits of life, this research direction can deepen the understanding of life. Secondly, my undergraduate major is related to thisresearch direction, I am keen on exploring the mystery in microcosm and able to do well in both practice and research. Thatis why I choose the cell biology as the direction of my research.",
                "2.  I have a strong interest in big data analysis and would like to make it my primary area of study. Data is the foundation of research, helping us to gain a deeper understanding of the content and methods of study. My major is closely related to this, and I enjoy the collision of mathematics and programming languages, as well as using them to complete tasks."],                
                id: "question26"
            },
            // 问题27
            {
                question: "未来规划问题3： plans or postgraduate study or expect to achieve or enrolled <br> Can you talk about your plans in the postgraduate study? <br> What do you expect to achieve during your study if you are enrolled into this institute?",
                answers: ["1. (学硕) I've already made a plan for my postgraduate study. In the first year, I will focus all my energy on studyingprofessional knowledge and mastering research methods in the field. Secondly, I will read all the books recommended bymy supervisors and read as many books as possible. The next year, I will determine my own research direction. At the same time, I will actively participate in the experiment and scientific research ofmy supervisors and do a good job in supportingwork. In the third year, I will try my best to write valuable papers with high level. Later, if possible, I will apply for adoctorate. All in all, I am looking forward to making a solid foundation for my profession and my life in this excellent university.",
                "2. 2、(专硕)I have made a plan for my own graduate life. If l have the opportunity to continue my studies, I will make good use of the two years in this university. In the first year, I will devote all my energy to studying professional knowledge andmastering research methods in the field. Secondly, I will make sure that I can be familiar with the latest development of thisarea by reading as many books and journals as possible. In the second year, I will look for an internship, because it canapply what I have leared to practical operations. At the same time, I will carefully prepare my graduation thesis. Later, Iwill apply for a PhD or find a job and become an expert in this field. In short, I look forward to laying a solid foundation formy profession and life at this excellent university."],                
                id: "question27"
            },
            // 问题28
            {
                question: "压力测试问题1： failed <br> If you failed this time,what will you do in the near future?",
                answers: ["1. It is clear that success and failure coexist in the life. lf I couldn't pass the test this time, it means that l am not adequate tosome extent, not only in the way of professional knowledge, but also in the practical aspect. I will face up to the issues, readmore professional books and practice myself under the guidance of acquired professions. Through these ways, I will spareno efforts to correct my imperfections. Regardless of what the result is, I will never give up on the pursuit ofmydream.",
                ""],                
                id: "question28"
            },
            // 问题29
            {
                question: "压力测试问题2： fail in this course <br> Why did you fail in this course?",
                answers: ["1. I'm so sorry, professors.l did have flunked one class before.l just joined t he Students’ Union at that time.There were somany affairs in the Students’ Union that I can not pay more atention to study.l have had a deep reflection since then.First,lunderstood that there is no shortcut to learing.Second.l couldn't be conceited.l will correct my attitude,draw a cleardistinction between the primary and the secondary,and strive for excellent results in every course.",
                ""],                
                id: "question29"
            },
            // 问题30
            {
                question: "压力测试问题3： course load was the heaviest <br> Tell us about the time when your course load was the heaviest and how did you get all of your work done?",
                answers: ["1. I think my heaviest course load came when I was a junior student at college.ln that spring semester,l took ll courses.lnaddition,I tried to tutor two middle school students in my spare time.Every day I was too occupied to even enjoy a meal atease.I'm the kind of people who seldom gives up.So i constantly encouraged myself to manage both study and workwell.You know I really had a strong sense of achievement at the end of that semester.",
                ""],                
                id: "question30"
            }
                ]
            },
            {
                math: [{
                        question: "1. 什么是统计学？",
                        answers: ["统计学是收集、处理、分析、表述和解释数据的科学。",""]
                    },
                    {
                        question: "2. 分析数据的常用方法(2种)",
                        answers: ["1. 描述性统计：",
                        "2. 推断统计："]
                    },
                    {
                        question:"3. 数据的计量尺度",
                        answers:["1. 定类尺度：",
                        "2. 定序尺度：",
                        "3. 定距尺度：",
                        "4. 定比尺度："]
                    },
                    {
                        question:"4. 数据的类型",
                        answers:["1. 计量尺度划分：",
                        "2. 被描述对象与时间的关系：",
                        "3. 数据的搜集(使用者角度)：",
                        "4. 数据的搜集方法："]
                    },
                    {
                        question:"5：基本概念-总体",
                        answers:["1. 总体：",
                        "2. 有限总体：",
                        "3. 无限总体："]
                    },
                    {
                        question:"6：基本概念-样本",
                        answers:["",
                        ""]
                    },
                    {
                        question:"7. 基本概念-参数",
                        answers:["",
                        ""]
                    },
                    {
                        question:"8. 基本概念-统计量",
                        answers:["",
                        ""]
                    },
                    {
                        question:"9. 基本概念-变量",
                        answers:["1. 变量：",
                        "2. 离散型变量：",
                        "3. 连续性变量：",
                        "4. 经验变量：",
                        "5. 理论变量："]
                    },
                    {
                        question:"10. 数据的来源",
                        answers:["1. 间接：",
                        "2. 直接："]
                    },
                    {
                        question:"11. 二手数据的特点和评估",
                        answers:["",
                        ""]
                    },
                    {
                        question:"12. 概率抽样的概念",
                        answers:["",
                        ""]
                    },
                    {
                        question:"13. 概率抽样种类",
                        answers:["",
                        ""]
                    },
                    {
                        question:"14. 非概率抽样概念",
                        answers:["",
                        ""]
                    },
                    {
                        question:"15. 非概率抽样种类",
                        answers:["",
                        ""]
                    },
                    {
                        question:"16. 抽样误差概念",
                        answers:["",
                        ""]
                    },
                    {
                        question:"17. 抽样误差的影响因素",
                        answers:["",
                        ""]
                    },
                    {
                        question:"18. 非抽样误差概念",
                        answers:["",
                        ""]
                    },
                    {
                        question:"19. 非抽样误差种类",
                        answers:["",
                        ""]
                    },
                    {
                        question:"20. 调查问卷内容",
                        answers:["",
                        ""]
                    },
                    {
                        question:"21. 数据预处理",
                        answers:["1. 数据审核：",
                        "2. 数据筛选：",
                        "3. 数据排序："]
                    },
                    {
                        question:"22. 统计分组概念和意义",
                        answers:["1. 概念：",
                        "2. 意义："]
                    },
                    {
                        question:"23. 统计分组的步骤",
                        answers:["1. 确定组数：",
                        "2. 确定组距：",
                        "3. 确定组限：",
                        "4. 绘制频数分布表"]
                    },
                    {
                        question:"24. 统计分组的分类",
                        answers:["1. 简单分组：",
                        "2. 平行分组体系：",
                        "3. 复合分组：",
                        "4. 复合分组体系："]
                    },
                    {
                        question:"25. 分类数据图示",
                        answers:["1. 条形图：",
                        "2. 帕累托图：",
                        "3. 饼图：",
                        "4. 环形图："]
                    },
                    {
                        question:"26. 顺序数据图示",
                        answers:["1.累计频数： 向上=，向下=",
                        "2. 累计频率： 向上=，向下="]
                    },
                    {
                        question:"27. 数值型数据图示",
                        answers:["1. 直方图：",
                        "2. 茎叶图：",
                        "3. 折线图：",
                        "4. 箱线图：",
                        "5. 散点图：",
                        "6. 气泡图：",
                        "7. 雷达图："]
                    },
                    {
                        question:"直方图，茎叶图，条形图的区别和联系",
                        answers:["",
                        ""]
                    },
                    
                    {
                        question:"28. 数据的集中趋势",
                        answers:["1. 平均数：简单算数平均数=，加权算数平均数=，几何平均数=",
                        "2. 中位数：",
                        "3. 众数："]
                    },
                    {
                        question:"29. 权数的概念和分类",
                        answers:["1. 权数：",
                        "2. 客观权数：",
                        "3. 主观权数："]
                    },
                    {
                        question:"30. 算术平均数，中位数，众数的关系",
                        answers:["1. 分布：",
                        "2. 特点和应用场合："]
                    },
                    {
                        question:"31. 数据的离散程度",
                        answers:["离散程度：各数据远离其中心值的程度",
                        "1. 分类数据：异众比率",
                        "2. 顺序数据：四分位差",
                        "3. 数值型数据：极差  平均差  方差和标准差",
                        "4. 相对位置：标准分数=变量值与平均值的离差除以标准差 <br> 经验法则=对称分布，68%+-1，95%+-2，99%+-3 <br> 切比雪夫不等式=不对称分布，75%+-2，89%+-3，94%+-4  ",
                        "5. 相对离散程度：离散系数=一组数据的标准差/平均值",
                        "6. 偏态与峰态：偏态系数=数据分布对称性的测度，峰态系数=数据平峰或尖峰的测度"]
                    },
                    {
                        question:"32. 统计量的相关概念",
                        answers:["1. 通缉令：",
                        "2. 词序通缉令：",
                        "3. 重分统计量："]
                    },
                    {
                        question:"33. 三种分布",
                        answers:["1. 总体分布：",
                        "2. 样本分布：",
                        "3. 抽样分布："]
                    },
                    {
                        question:"",
                        answers:["",
                        ""]
                    },
                    {
                        question:"",
                        answers:["",
                        ""]
                    },
                    {
                        question:"",
                        answers:["",
                        ""]
                    },
                    {
                        question:"",
                        answers:["",
                        ""]
                    },
                    {
                        question:"",
                        answers:["",
                        ""]
                    },

                ]
            }
        ];

        function showQuestions(subject) {
            homeContainer.style.display = 'none';
            questionContainer.classList.remove('hidden');
            renderQuestions(subject);
        }

        function renderQuestions(subject) {
            questionContainer.innerHTML = '';
            const subjectQuestions = questionsAndAnswers.find(item => item.hasOwnProperty(subject))[subject];
            const currentQuestion = subjectQuestions[currentQuestionIndex];
            renderQuestion(currentQuestion);

            const buttonContainer1 = document.createElement('div');
            buttonContainer1.classList.add('button-container1');

            buttonContainer1.appendChild(createToggleAnswerButton(), );

            buttonContainer1.appendChild(createButton('百度翻译', 'fanyi', () => {
                window.open('https://fanyi.baidu.com/', '_blank');
            }));

            // buttonContainer1.appendChild(createButton('播放问题', 'return-home', () => {
            //     // alert(currentQuestion.answers)
            //     playQuestion(currentQuestion.question);
            // }));
            // buttonContainer1.appendChild(createButton('播放答案', 'return-home', () => {
            //     playAnswer(currentQuestion.answers.join('.'));
            // }));
            buttonContainer1.appendChild(createButton('返回首页', 'return-home', () => {
                returnHome();
            }));

            questionContainer.appendChild(buttonContainer1);

            const buttonContainer2 = document.createElement('div');
            buttonContainer2.classList.add('button-container2');

            buttonContainer2.appendChild(createButton('上一题', 'prev-question', () => {
                if (currentQuestionIndex > 0) {
                    currentQuestionIndex--;
                    renderQuestion(subjectQuestions[currentQuestionIndex]);
                }
            }));

            buttonContainer2.appendChild(createButton('随机题目', 'random-question', () => {
                currentQuestionIndex = Math.floor(Math.random() * subjectQuestions.length);
                renderQuestion(subjectQuestions[currentQuestionIndex]);
            }));

            buttonContainer2.appendChild(createButton('下一题', 'next-question', () => {
                if (currentQuestionIndex < subjectQuestions.length - 1) {
                    currentQuestionIndex++;
                    renderQuestion(subjectQuestions[currentQuestionIndex]);
                }
            }));

            
            questionContainer.appendChild(buttonContainer2);

            
        }
        const questionState = {  
            isAnswerHidden: true  
        }; 
        function createToggleAnswerButton() {  
            const button = createButton(questionState.isAnswerHidden ? '显示答案' : '隐藏答案', 'toggle-answer', () => {  
                const newDisplay = questionState.isAnswerHidden ? 'block' : 'none';  
                document.querySelector('.answer').style.display = newDisplay;  
                questionState.isAnswerHidden = !questionState.isAnswerHidden;  
                // 更新按钮文本  
                button.textContent = questionState.isAnswerHidden ? '显示答案' : '隐藏答案';  
            });  
            // 设置按钮的id  
            button.id = 'show-hide-answer';  
            return button;  
        }  

        function renderQuestion(questionData) {
            const questionDiv = document.createElement('div');
            questionDiv.classList.add('question-container');
            questionDiv.innerHTML = `
                <div class="question">${questionData.question}</div>
                <div class="answer">
                    <p>${questionData.answers.join('<br>')}</p>
                </div>
                <div class="speed-container">  
                    <button class="button play-question" onclick="playQuestion('${questionData.question}')">播放问题</button>
                    <label for="speed" id="speed-describtion">播放速度(默1):</label>  
                    <input type="range" id="speed" min="0.1" max="2" value="1" step="0.1"> 
                    <button class="button play-answer" onclick="playAnswer('${questionData.answers}')">播放答案</button> 
                </div>
            `;
            if (questionContainer.firstChild) {
                questionContainer.replaceChild(questionDiv, questionContainer.firstChild);
                // 重置答案隐藏状态为true  
                questionState.isAnswerHidden = true;  
                const answerElement = document.querySelector('.answer');  
                if (answerElement) {  
                    answerElement.style.display = 'none';  
                }  
            
                // 更新按钮文本  
                const button = document.getElementById('show-hide-answer');  
                if (button) {  
                    button.textContent = questionState.isAnswerHidden ? '显示答案' : '隐藏答案';  
                }  
            } else {
                questionContainer.appendChild(questionDiv);
            }
        }
        function returnHome() {
            homeContainer.style.display = 'flex';
            questionContainer.classList.add('hidden');
            currentQuestionIndex = 0;
        }

        function createButton(text, className, onClickFunction) {
            const button = document.createElement('button');
            button.textContent = text;
            button.classList.add('button', className);
            button.onclick = onClickFunction;
            return button;
        }
        // 播放问题的函数  
        function playQuestion(text) { 
            // 检查SpeechSynthesis API是否可用  
            if (!window.speechSynthesis) {  
                alert('SpeechSynthesis API is not available.');  
                return;  
            } 

            if (isPlaying1) {  
                if (utterance) {  
                    synth.cancel();  
                    utterance.cancel(); // 如果正在播放，则取消当前播放  
                }  
                isPlaying1 = false; // 确保状态被正确更新  
            } else {  
                utterance = new SpeechSynthesisUtterance(text.trim());  
                // utterance.lang = 'en-US'; // 设置语言为英文  
                utterance.rate = parseFloat(document.getElementById('speed').value); // 获取播放速度1  
                synth.speak(utterance); // 开始播放  
                isPlaying1 = true;  
                
                // 添加语音播放结束的事件监听器  
                utterance.onend = function() {  
                    isPlaying1 = false; // 确保在播放结束时状态被正确更新  
                };  
            }  
        }  
        
        // 播放答案的函数  
        function playAnswer(text) {  
            // 检查SpeechSynthesis API是否可用  
            if (!window.speechSynthesis) {  
                alert('SpeechSynthesis API is not available.');  
                return;  
            }  
        
            // 清理文本中的特殊字符  
            text = cleanText(text);  
        
            if (isPlaying) {  
                if (utterance) {  
                    synth.cancel();  
                    utterance.cancel(); // 如果正在播放，则取消当前播放  
                }  
                isPlaying = false; // 确保状态被正确更新  
            } else {  
                utterance = new SpeechSynthesisUtterance(text.trim());  
                // utterance.lang = 'en-US,zh-cn'; // 设置语言为英文
                utterance.rate = parseFloat(document.getElementById('speed').value); // 获取播放速度  
                utterance.onerror = function(event) {  
                    console.error('An error occurred in the speech synthesis:', event);  
                };  
                
                synth.speak(utterance); // 开始播放  
                isPlaying = true;  
                
                utterance.onend = function() {  
                    isPlaying = false; // 确保在播放结束时状态被正确更新  
                };  
            }  
        }  
        
        // 辅助函数：清理文本中的特殊字符  
        function cleanText(text) {  
            // 这里可以根据需要添加清理逻辑，例如移除HTML标签、转义字符等  
            // 例如，使用正则表达式替换所有非打印字符：  
            return text.replace(/[^\x20-\x7E]/g, '');  
        }
    </script>
</body>

</html>